#include<stdio.h>
#include<stdlib.h>

struct Node
{
     int data;
     struct Node * left;
     struct Node * right;
     struct Node * parent;
};

struct BinarySearchTree
{
     int size;
     struct Node root;
};

int size()
{
     return size;
}
int isEmpty(struct BinarySearchTree * tree)
{
     return tree->size == 0;
}
int clear()
{

}
int add(struct BinarySearchTree * tree,int element)
{
     if (tree->root == NULL)
     {
          //添加第一个结点
          tree = malloc(sizeof(struct BinarySearchTree));
          tree->root.data = element;
     }
     //添加的不是第一个结点
     struct Node node = tree->root;
     while (node != NULL)
     {
          int cmp = compare(element, node.data);
          if (cmp > 0)
          {
               node = *node.right;
          }
          if (cmp < 0)
          {
               node = *node.left;
          }
          else
               return;
     }
}
int compare(int ele1,int ele2)
{
     return ele1-ele2;
}
int remove()
{

}
int contains()
{

}